<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN""DTD/xhtml1-strict.dtd">
<%@page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<%@taglib uri="/WEB-INF/c.tld" prefix="c"%>
<%@taglib uri="/WEB-INF/fmt.tld" prefix="fmt"%>
<%@taglib uri="/WEB-INF/el.tld" prefix="el"%>
<%@taglib uri="/WEB-INF/fn.tld" prefix="fn"%>
<html>
	<head>
		<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
		<title></title>
		<c:import url="/includes/css_inc.jsp"/>
		<c:import url="/includes/js_inc.jsp"/>
		<script>
			$(function(){
				$("#saveProvice").button({
		            icons: {
		                primary: "ui-icon-power"
		            }
				}).click(function(){
					$("#listForm").submit();
				});
				$("#edit").button({
		            icons: {
		                primary: "ui-icon-disk"
		            }
				}).click(function(){
					$("#listForm").submit();
				});
			});
		</script>
	</head>
	<body>
		<c:import url="/apps/msg.jsp"/>
		<form class="acc67-form" name="listForm" id="listForm" action="${pageContext.request.contextPath}/acc7" method="post">
		<input type="hidden" name="app" id="app" value="ACC70202"/>
		<input type="hidden" name="job" id="job" value="${job}"/>
		<table width="100%" class="ui-widget ui-widget-content" border="0">
			<tr>
				<th align="left" class="acc67-header ui-widget-header" colspan="0"><b>${screenCode.ACC70202}</b></th>
			</tr>
			<c:if test="${job == 'saveProvince'}">
				<tr>
					<td align="center"><button type="button" name="saveProvice" id="saveProvice" class="acc67-button">ดึงข้อมูลจังหวัด</button></td>
				</tr>
			</c:if>
			<c:if test="${!empty provinceAccountBean}">
				<tr>
					<td>
						<fieldset>
							<legend> ข้อมูลบัญชีจังหวัด </legend>
								<table width="100%" class="acc67-grid ui-widget ui-widget-content" border="0">
									<tr>
										<th  align="center" class="ui-state-default" width="10%">รหัสจังหวัด</th>
										<th  align="center" class="ui-state-default">ชื่อจังหวัด</th>
										<th  align="center" class="ui-state-default">ชื่อบัญชีจังหวัด</th>
										<th  align="center" class="ui-state-default" width="8%">เลขที่บัญชีจังหวัด</th>
									</tr>
									<c:forEach var="data" items="${provinceAccountBean}" varStatus="x">
										<input type="hidden" name="provinceId" id="provinceId" value="${data.provinceId}">
										<tr class="grid-tr-${x.count % 2}">
											<td align="center">${data.provinceId}</td>
											<td align="left">${data.provinceName}</td>
											<td>
												<%-- <input type="text" name="provinceAccountName" size="70" id="provinceAccountName" value="${data.provinceAccountName}"> --%>
												${data.provinceAccountName}
											</td>
											<td align="center">
												<%-- <input type="text" name="provinceAccount" id="provinceAccount" maxlength="13" onkeypress="return numberOnly(event)" value="${data.provinceAccount}"> --%>
												${data.provinceAccount}
											</td>
										</tr>
									</c:forEach>
		<!-- 							<tr>
										<td colspan="4" align="center">
											<button type="button" name="edit" id="edit" class="acc67-button"> บันทึกข้อมูล </button>
										</td>
									</tr> -->
								</table>
						</fieldset>
					</td>
				</tr>
			</c:if>
			</table>
		</form>
	</body>
</html>